package mr.ali.video.web.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import mr.ali.video.web.mapper.JujiSeriesMapper;
import mr.ali.video.web.model.JujiSeries;
import mr.ali.video.web.service.IJujiSeriesService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * <p>
 * 服务实现类
 * </p>
 *
 * @author Mr-ali
 * @since 2025-08-04
 */
@Service
public class JujiSeriesServiceImpl extends ServiceImpl<JujiSeriesMapper, JujiSeries> implements IJujiSeriesService {
    @Resource
    private JujiSeriesMapper jujiSeriesService;

    @Override
    public List<JujiSeries> getJujiSeriesList() {
        QueryWrapper<JujiSeries> queryWrapper = new QueryWrapper<>();
        queryWrapper.orderByDesc("gmt_create");
        return jujiSeriesService.selectList(queryWrapper);
    }
    @Override
    public Integer insertJujiSeries(JujiSeries jujiSeries) {
        return jujiSeriesService.insert(jujiSeries);
    }
}
